package fasilkom.antz.sprite;

import java.awt.Graphics2D;

import com.golden.gamedev.object.Sprite;

import fasilkom.antz.Antz;


public class ItemSprite extends Sprite {

	private static final long serialVersionUID = 4274094491633642381L;
	
	public static final int ANTZ = 0;
	public static final int POTION = 1;
	public static final int ENERGY_POTION = 2;
	public static final int DOUBLE_ATTACK = 3;
	public static final int DOUBLE_DEFENSE = 4;
	public static final int GOAL = 5;
	public static final int MAP = 6;
	
	private String pic;
	
	public boolean isSaved;
	public int type;
	
	public ItemSprite(Antz main, int type) {
		super();
		
		this.type = type;
		
		if(type == ANTZ){
			pic = "assets/AntzSaved.png";
		}
		else if(type == POTION){
			pic = "assets/potion.png";
		}
		else if(type == ENERGY_POTION){
			pic = "assets/energy.png";
		}
		else if(type == GOAL){
			pic = "assets/goal.png";
		}
		else if(type == MAP){
			pic = "assets/map.png";
		}
		
		setImage(main.getImage(pic));
		
		if(type != GOAL){
			setActive(false);
			setImmutable(false);
		}
		isSaved = false;
	}
	
	@Override
	public void render(Graphics2D g) {
		super.render(g);
	}
}
